<html xmlns="http://www.w3.org/1999/xhtml" xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core"
	xmlns:c="http://java.sun.com/jsp/jstl/core" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:p="http://primefaces.org/ui">

<ui:composition>
	<div class="header">

		<h:form id="headForm" prependId="false">
			<div class="top">
				<div class="topwrap">
					<div class="topwrapleft">
						<ul>
							<li><a href="http://www.weibo.com/yourhotdeal" target="_BLANK">weibo</a>|</li>
							<li><a href="https://www.facebook.com/yourhotdeals" target="_BLANK">facebook</a>|</li>
							<li><a href="https://twitter.com/yourhotdeal" target="_BLANK">Twitter</a>|</li>
							<li><a href="">google+</a>|</li>
							<li><a href="">wechat</a></li>
						</ul>
					</div>
					<div class="topwrapright">
						<ul>

							<li><p:commandLink action="#{login.initEnroll()}" rendered="#{!login.userLoggedIn}" ajax="false" styleClass="tip">
										#{msgs.newUserBonus}
									</p:commandLink></li>

							<li><p:commandLink action="#{userBackingBean.openUserProfile(constants.nameToValueMap.USER_TAB_TELL_A_FRIEND)}"
									value="#{msgs.referUserBonus} " rendered="#{login.userLoggedIn}" ajax="false" styleClass="tip">
								</p:commandLink></li>

							<li><p:commandLink action="#{login.initLogin()}" value="#{msgs.SignIn} " rendered="#{!login.userLoggedIn}" ajax="false">
								</p:commandLink></li>

							<li><h:panelGroup rendered="#{login.userLoggedIn}">
									<p:commandLink value="#{msgs.Hello} #{login.currentUser.userId}" action="#{userBackingBean.openUserProfile}" global="false" ajax="false"></p:commandLink>
								</h:panelGroup></li>

							<li><p:commandLink action="#{login.logOut}" value="#{msgs.LogOut}" disabled="#{!login.userLoggedIn}" ajax="false" /></li>

							<li><h:link id="messagesNumberx" value="#{msgs.Message} #{sessionScope.NumberOfNewMessages}" outcome="/message/messagebox.xhtml"
									rendered="#{login.userLoggedIn}" /></li>
							<li><h:link outcome="/threadStaging/listThreadStaging.xhtml" value="#{msgs.StagingDeal}"
									rendered="#{login.isUserInSysadmin() || login.isUserOwnerOfAnyCategory(login.getCurrentUser())}" /></li>
							<li><h:link outcome="/system/managePendingThread.xhtml" value="#{msgs.PendingThread}"
									rendered="#{login.isUserInSysadmin() || login.isUserOwnerOfAnyCategory(login.getCurrentUser())}" /></li>
							<li><h:link outcome="/system/index.xhtml" value="${msgs.SystemAdmin}" rendered="#{login.isUserInSysadmin()}"></h:link></li>
							<li><h:outputFormat value="#{msgs.Online_User}">
									<f:param value="#{onlineCounter.counter}"></f:param>
								</h:outputFormat></li>

						</ul>
					</div>
				</div>
			</div>
			<!--top over-->
			<div class="headerL2">
				<div class="header_w">
					<div class="logo">
						<h:link outcome="/index.xhtml" title="#{msgs.Home}">
							<h:graphicImage name="logo2.jpg" library="images" alt="Home" />
						</h:link>
					</div>
					<div class="search">
						<ui:remove>
							<ui:include src="/search.xhtml"></ui:include>
						</ui:remove>
					</div>

					<div class="gg">
						<ui:include src="/ad/selfAd.xhtml"></ui:include>
					</div>
				</div>
			</div>

			<div class="nav1">
				<div class="nav_a">
					<ul>
						<li><h:link id="home" outcome="/index.xhtml" value="#{msgs.Home}" /></li>
						<li>|</li>
						<li><h:link id="hotDeal" outcome="/category/indexthreads4AllCategory.xhtml">
					 #{msgs.HotDeals}(<span class="numOfDeals4Today">#{threadCacheEjb.numberOfDeals4Today} #{msgs.dealsToday}</span>)
						</h:link></li>

						<li>|</li>
						<li><h:link id="listStore" outcome="/stores/listStore.xhtml" value="#{msgs.Store}" /></li>
						<li>|</li>
						<li><h:link id="cashBack" outcome="/help/help.xhtml">#{msgs.CashBack}<span class="red">(New)</span>
							</h:link></li>

					</ul>
				</div>
			</div>
			<div id="categoryMenu">
				<div class="nav2">
					<p:menubar model="#{menuBean.menuModel}" styleClass="nav_b"></p:menubar>
				</div>
			</div>

		</h:form>

	</div>
</ui:composition>
</html>
